/**
 * 20080102 1710: Eric Kao was modified.
 */

package util.string;

import com.e885.log.E885Logger;
import com.e885.util.string.StringUtil;

/**
 * 
 * <br>
 * Copyright: Copyright (c) 2001-2008<br>
 * Company: E885 Group
 * 
 * @author Eric.Kao(gau168.gau@msa.hinet.net)
 * @version 1.0
 */
public class Reverse
{
	public Reverse()
	{
		/**
		 * 間隔符號為 " "
		 */
		String str1 = "This is a test";

		String reverseStr1 = StringUtil.reverse( str1 );

		E885Logger.testLog.debug( "reverseStr1:" + reverseStr1 );

		/**
		 * 間隔符號為 ","
		 */
		String str2 = "This,is,a,test";

		String reverseStr2 = StringUtil.reverse( str2, "," );

		E885Logger.testLog.debug( "reverseStr2:" + reverseStr2 );

		/**
		 * 使用中文
		 */
		String str3 = "我;是;王;小;明";

		String reverseStr3 = StringUtil.reverse( str3, ";" );

		E885Logger.testLog.debug( "reverseStr3:" + reverseStr3 );

		/**
		 * 傳入參數 null
		 */

		String reverseStr4 = StringUtil.reverse( null );

		E885Logger.testLog.debug( "reverseStr4:" + reverseStr4 );
	}

	/**
	 * @param args
	 */
	public static void main( String[] args )
	{
		new Reverse();
	}

}
